package code1_100.code1_10;

//回文数
public class Code9 {
    static class Solution {
        public boolean isPalindrome(int x) {
            if(x<0 || (x%10==0&&x!=0))
                return false;
            int res = 0;
            int star = x;
            while(x!=0){
                res = res *10+x%10;
                x=x/10;
            }
            System.out.println(res);

            return star==res;
        }
    }
}
